package com.myk.game.gobangchess.utils;

import java.net.URISyntaxException;

public class PathUtils {
    /**
     * 获取程序根目录，支持路径中有中文
     */
    public static String getRootPath() {
        String path;
        try {
            path = PathUtils.class.getResource("/").toURI().getPath();
        } catch (URISyntaxException e) {
            e.printStackTrace();
            path = System.getProperty("user.dir");
        }
        return path;
    }

}
